package service;

import pojo.Book;

import java.util.List;

/**
 * @author 陈Ser
 * @ClassName Bookervice
 * @description: TODO
 * @Date 2021/9/28 9:58
 * @Version 1.0
 */
public interface BookService {


    /**
     * add
     *
     * @param book book
     * @return length
     */
    int addBook(Book book);


    /**
     * delete
     *
     * @param id id
     * @return length
     */
    int deleteBookById(int id);

    /**
     * update
     *
     * @param book book
     * @return length
     */
    int updateBook(Book book);

    /**
     * query
     *
     * @param id id
     * @return book
     */
    Book queryBookById(int id);

    /**
     * query
     *
     * @return books of List
     */
    List<Book> queryAllBook();
}
